<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<script type="text/javascript">
    $(document).ready(function(){
        $("#memberTable").datagrid({
            height:"100%",
            tableWidth:"100%",
            showToolbar:true,
            dataUrl:"<c:url value="/member/data"/>"
        });
    });

    function datagrid_tree_operation(value){
		var html = "<a href=\"javascript:void(0);\" class=\"btn btn-default\" data-toggle=\"edit.datagrid.tr\" data-options=\"{dialog:{url:'<c:url value="/member/details"/>?id={id}',width:'920',title:'用户详情'}}\">详情</a>";
		html += "<a href=\"javascript:void(0);\" class=\"btn btn-default\" data-toggle=\"edit.datagrid.tr\" data-options=\"{dialog:{url:'<c:url value="/member/moneyLogs"/>?id={id}',width:'1380',height:'600'}}\">资金记录</a>"
		html += "<a href=\"javascript:void(0)\" class=\"btn btn-default\" data-toggle='edit.datagrid.tr' data-options=\"{dialog:{url:'<c:url value="/member/tenderLog"/>?userId={id}',width:'1280',height:'600'}}\">投资记录</a>";
		return html;
    }
</script>
<div class="bjui-pageContent">
    <table class="table table-bordered" id="memberTable">
    	<thead>
    		<tr>
    			<th data-options="{name:'id'}">编号</th>
    			<th data-options="{name:'username'}">用户名</th>
    			<th data-options="{name:'mobile'}">手机号码</th>
    			<th data-options="{name:'email'}">邮箱</th>
    			<th data-options="{render:datagrid_tree_operation}">操作</th>
    		</tr>
    	</thead>
    </table>
</div>